<template>
<div class="rank_f" >
    <div class="rank_simple" @mouseenter="detail($event)" @mouseleave="simple($event)">
        <div>
            <div >title1</div>
            <div >author</div>
            <div aria-controls="">item</div>
        </div> 
        <div>item</div>
        <div>
            <div class="bgc" v-show="!show">
                <img src="../assets/36107941.jpg" alt="">
            </div>
        </div>
    </div>
    <div class="rank_simple" name="2" @mouseenter="detail($event)" @mouseleave="simple($event)">
        <div>
            <div >title2</div>
            <div >author</div>
            <div aria-controls="">item</div>
        </div> 
        <div>item</div>
        <div>
            <div class="bgc" v-show="!show">
            </div>
        </div>
    </div>
    <div class="rank_simple" name="3" @mouseenter="detail($event)" @mouseleave="simple($event)">
        <div>
            <div >title3</div>
            <div >author</div>
            <div aria-controls="">item</div>
        </div> 
        <div>item</div>
        <div>
            <div class="bgc" v-show="!show">
            </div>
        </div>
    </div>
</div>
</template>
<script>

export default {
    data(){
        return{
            show:false,
        }
    },
    methods:{
        detail(e){
            e.target.className='rank';
        },
        simple(e){
            e.target.className='rank_simple';
        },
    },
}
</script>
<style>
.rank{
    display: flex;
    justify-content: space-between;
    width: 200px;
    height: 100px;
    background-color: pink;
}
.bgc{
       width: 80px;
       height: 120px;
       background-image: url('../assets/36107941.jpg');
       background-size: contain;
    }
.rank>div:nth-child(2){
    display: none;
}
.rank_simple{
    display: flex;
    width: 200px;
    height: 100px;
    background-color: pink;
}
.rank_simple>div:nth-child(1)>div+div{
    display: none;
}
.rank_simple>div:nth-child(2){
    display: block;
}
.rank_simple>div:nth-child(3){
    display: none;
}
</style>

